home *** CD-ROM | disk | FTP | other *** search
- /****************************************************************************
- * source\msdos\config.h
- *
- * This file contains the machine specific defines for a 32-bit protected
- * mode msdos compile under several different compilers.
- *
- * from Persistence of Vision(tm) Ray Tracer
- * Copyright 1996 Persistence of Vision Team
- *---------------------------------------------------------------------------
- * NOTICE: This source code file is provided so that users may experiment
- * with enhancements to POV-Ray and to port the software to platforms other
- * than those supported by the POV-Ray Team. There are strict rules under
- * which you are permitted to use this file. The rules are in the file
- * named POVLEGAL.DOC which should be distributed with this file. If
- * POVLEGAL.DOC is not available or for more info please contact the POV-Ray
- * Team Coordinator by leaving a message in CompuServe's Graphics Developer's
- * Forum. The latest version of POV-Ray may be found there as well.
- *
- * This program is based on the popular DKB raytracer version 2.12.
- * DKBTrace was originally written by David K. Buck.
- * DKBTrace Ver 2.0-2.12 were written by David K. Buck & Aaron A. Collins.
- * Rev. 6/7/94
- *****************************************************************************/
-
- #ifndef CONFIG_H
- #define CONFIG_H
-
- /* Comment out the defines below if you are not using the fancy text
- * routines in MSDOSTXT.C or video in MSDOSVID.C
- */
-
- /*
- #define FANCY_TEXT
- */
- #define FANCY_VIDEO
-
- /*****************
- *
- * Note: These compiler specific defines should only contain items
- * that are likely to affect the generic parts of POV-Ray. Any video
- * specific stuff belongs in MSDOSVID.C. Any text specific stuff belongs
- * in MSDOSTXT.C. Any items common to video and text belongs in MSDOSALL.H.
- ****************/
-
- void main(int, char **);
- double fmod(double, double);
- #define COMPILER_VER ".tos.gcc.2.7.2"
-
- #define PRECISION_TIMER_AVAILABLE 1
- #define PRECISION_TIMER_INIT ZTimerInit () ;
- #define PRECISION_TIMER_START LZTimerOn() ;
- #define PRECISION_TIMER_STOP LZTimerOff() ;
- #define PRECISION_TIMER_COUNT LZTimerCount() ;
-
- #define START_TIME xtime(&tstart);
- #define STOP_TIME xtime(&tstop);
-
- /*
- #define START_TIME time(&tstart);
- #define STOP_TIME time(&tstop);
- */
-
- #include <compiler.h>
- #include <stdarg.h>
- #include <stdlib.h>
- #include <time.h>
- #include <times.h>
- #include <timeb.h>
- #include <utime.h>
-
- /* Un comment at most one of these options
- #define MEM_TAG - Enables memory tag debugging
- #define MEM_RECLAIM - Enables garbage collection
- */
-
- #define MEM_TRACE
- #define MEM_STATS 1
-
- #define FILENAME_SEPARATOR '\\'
-
- #define EPSILON 1.0e-5
-
- #define DEFAULT_OUTPUT_FORMAT 't'
- #define NEW_LINE_STRING "\r\n"
-
- /* defines for machine-specific PaletteOption settings */
- #define NORMAL '0'
- #define GREY 'G'
- #define HSV '0'
- #define P_332 '3'
- #define HICOLOR 'H' /* 16 bits/pixel "high" color */
- #define FULLCOLOR 'T' /* 24 bits/pixel "true" color */
-
- #define RENAME_FILE(orig,new) rename(orig,new)
-
- void MSDOS_Startup(void);
- int MSDOS_System(char *s);
- void MSDOS_Process_Povray_Ini(char *s);
- void MSDOS_Process_Env(void);
- void MSDOS_Other_Credits(void);
-
- #define STARTUP_POVRAY MSDOS_Startup();
- #define POV_SYSTEM(s) MSDOS_System(s);
- #define PROCESS_POVRAY_INI MSDOS_Process_Povray_Ini(argv[0]);
- #define READ_ENV_VAR MSDOS_Process_Env();
- #define PRINT_OTHER_CREDITS if (argc>1) {Print_Authors(); MSDOS_Other_Credits(); }
- #define CONST const
-
- #define WAIT_FOR_KEYPRESS Crawcin();
- #define GET_KEY(x) { (x) = Crawcin(); }
- #define TEST_ABORT if (opts.Options & EXITENABLE) { if (Cconis()) { Stop_Flag = TRUE; Crawcin(); }}
- #define FINISH_POVRAY(n) exit(n);
-
- #ifdef FANCY_VIDEO
-
- void V_Init (int w, int h, unsigned long v, unsigned char f);
- /*
- void V_Fin (void);
- */
- void V_Close (void);
- void V_Plot (int x, int y, unsigned char r,
- unsigned char g, unsigned char b);
- void V_Rect (int x1, int x2, int y1, int y2,
- unsigned char r, unsigned char g, unsigned char b);
- void V_Box (int x1, int x2, int y1, int y2,
- unsigned int r, unsigned int g, unsigned int b);
-
- #define POV_DISPLAY_FINISHED Display_Finished();
- #define POV_DISPLAY_INIT(w,h,v,f) V_Init ((w), (h), (v), (f));
- #define POV_DISPLAY_CLOSE V_Close();
- #define POV_DISPLAY_PLOT(x,y,r,g,b,a) V_Plot((x),(y),(r),(g),(b));
- #define POV_DISPLAY_PLOT_RECT(x1,x2,y1,y2,r,g,b,a) V_Rect((x1),(x2),(y1),(y2),(r),(g),(b));
- #define POV_DISPLAY_PLOT_BOX(x1,x2,y1,y2,r,g,b,a) V_Box((x1),(x2),(y1),(y2),(r),(g),(b));
-
- #endif
-
- #endif
-